﻿@model qltscd.Models.BaseClient.DanhMucNhomNguoiDung
@{
    ViewBag.Title = "SuaNhomNguoiDung";
    Layout = "~/Views/Shared/Modules/_LayoutHeThong.cshtml";
}
<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>
<script>
    function submitTaoNhomNguoiDung(kieu) {
        document.getElementById("kieu").value = kieu;
        document.forms["TaoNhomNguoiDung"].submit();
    }
</script>
@using (Html.BeginForm("SuaNhomNguoiDung", "DanhMucNhomNguoiDung", FormMethod.Post, new { @id = "TaoNhomNguoiDung" })) {
    @Html.ValidationSummary(true);
    @Html.HiddenFor(o => o.IdentityNhomNguoiDung)
    <input type="hidden" value="0" name="kieu" id="kieu" />                            
    <fieldset>
        <legend>Danh Mục Nhóm Người Dùng</legend>
        <table border="0" width="100%" cellpadding="10px" cellspacing="10px">
            <tr>
                <td style="margin-left: 10px;" class="label_col">
                    Mã nhóm người dùng
                </td>
                <td>
                    @Html.TextBoxFor(Model => Model.MaNhomNguoiDung, new { @style = "width:97%; " })
                     
                </td>
            </tr>
            <tr>
                <td style="margin-left: 10px;" class="label_col">
                    Tên nhóm người dùng
                </td>
                <td>
                    @Html.TextBoxFor(Model => Model.TenNhomNguoiDung, new { @style = "width:97%; " })
                    
                </td>
            </tr>
            <tr>
                <td style="margin-left: 10px;" class="label_col">
                    Quyền
                </td>
                <td>
                    @Html.TextBoxFor(Model => Model.Quyen, new { @style = "width:97%; " })
                    
                </td>
            </tr>
        </table>
    </fieldset>
    <div class="divButton">
        <input type="button" value="Lưu" class="button" onclick="submitTaoNhomNguoiDung(0)" />&nbsp;
        <input type="button" value="Lưu và nhập mới" class="button" onclick="submitTaoNhomNguoiDung(1)" />&nbsp;
        <input type="reset" value="Nhập lại" class="button" />&nbsp;
        @Html.ActionLink("Thoát", "Index", null, new { @class = "button" })
    </div>
    
}
@*<div>
    @Html.ActionLink("Back to List", "Index")
</div>*@
<div class="errBlock">
                    @Html.ValidationMessageFor(Model => Model.MaNhomNguoiDung, "", new { @style = "display:block" })
                   
                        @ViewData[qltscd.Contansts.SessionConstants.ERROR_MESSAGE]
                    <br />
                    @Html.ValidationMessageFor(Model => Model.TenNhomNguoiDung, "", new { @style = "display:block" })
                    @Html.ValidationMessageFor(Model => Model.Quyen, "", new { @style = "display:block" })</div>
